package top.tangyh.lamp.care.service;

import top.tangyh.basic.base.service.SuperService;
import top.tangyh.lamp.care.entity.BExeYaoEvent;
import top.tangyh.lamp.care.vo.RevokeRecordYaoOutVO;
import top.tangyh.lamp.care.vo.query.*;
import top.tangyh.lamp.care.vo.result.ExeYaoOiOutVO;
import top.tangyh.lamp.care.vo.result.ExeYaoOutVO;
import top.tangyh.lamp.care.vo.save.BExeYaoEventSaveVO;
import top.tangyh.lamp.care.vo.save.ExeYaoEventInVO;
import top.tangyh.lamp.care.vo.save.ExeYaoInVO;
import top.tangyh.lamp.care.vo.update.BExeYaoEventUpdateVO;
import top.tangyh.lamp.care.vo.result.BExeYaoEventResultVO;
import top.tangyh.lamp.care.vo.update.UpdateExeYaoInVO;

import java.util.List;


/**
 * <p>
 * 业务接口
 * 用药执行事件表
 * </p>
 *
 * @author zqb
 * @date 2024-07-26 10:31:52
 * @create [2024-07-26 10:31:52] [zqb] [代码生成器生成]
 */
public interface BExeYaoEventService extends SuperService<Long, BExeYaoEvent> {

    void addEvent(ExeYaoEventInVO inVO);

    void deleteEvent(Long id);


    /**
     * 执行用药查询(去掉事件相关逻辑)
     *
     * @param queryVO
     * @return
     */
    List<ExeYaoOutVO> selectExeYaoListNoEventByQuery(ExeYaoQueryVO queryVO);

    List<ExeYaoOiOutVO> countUsedByTimeRangeHospitalNumber(ExeYaoOiQueryVO queryVO);

    /**
     * 根据主药id获取一组用药
     *
     * @param id
     */
    ExeYaoOutVO getYaoByMastId(Long id);


    /**
     * 新增用药 补录
     *
     * @param inVO
     */
    void addExeYao(ExeYaoInVO inVO);

    /**
     * 修改用药
     *
     * @param inVO
     */
    void updateExeYao(UpdateExeYaoInVO inVO);


    /**
     * 删除用药
     *
     * @param inVO
     */
    void deleteExeYao(DelExeYaoInVO inVO);

    Boolean updateMaster( Long id  ,Long oldMasterId);


    /**
     * 查询所有撤销记录
     *
     * @return
     */
    List<RevokeRecordYaoOutVO> selectRevokeRecords(String hospitalNumber);

    /**
     * 撤销删除的用药
     *
     * @param records
     */
    void revokeDeleteExeYao(List<RevokeInVO> records);
}


